/**
* @author:kellen
* @contact:xiekellen@hotmail.com
* @company:achivo-gz
* @created on:
* @modified on:
*/

package com.sasis.service.impl;

import java.util.List;

import com.sasis.service.impl.BaseManager;
import com.sasis.model.Hotel;
import com.sasis.dao.HotelDao;
import com.sasis.service.HotelManager;

import com.sasis.util.PageList;
import com.sasis.util.PageRequest;

public class HotelManagerImpl extends BaseManager implements HotelManager {
    private HotelDao dao;

    /**
     * Set the Dao for communication with the data layer.
     * @param dao
     */
    public void setHotelDao(HotelDao dao) {
        this.dao = dao;
    }

    /**
     * @see com.sasis.service.HotelManager#getHotels(com.sasis.model.Hotel)
     */
    public List getHotels(final Hotel hotel) {
        return dao.getHotels(hotel);
    }

    /**
     * @see com.sasis.service.HotelManager#getHotel(String id)
     */
    public Hotel getHotel(final String id) {
        return dao.getHotel(new Integer(id));
    }

    /**
     * @see com.sasis.service.HotelManager#saveHotel(Hotel hotel)
     */
    public void saveHotel(Hotel hotel) {
        dao.saveHotel(hotel);
    }

    /**
     * @see com.sasis.service.HotelManager#removeHotel(String id)
     */
    public void removeHotel(Hotel hotel) {
        dao.removeHotel( hotel);
    }
    public PageList queryForPageList(String listStatementId,  
    		Object parameterObject, PageRequest pageRequest){
	return dao.queryForPageList(listStatementId,   parameterObject, pageRequest);
    }
}
